<?php

/* This script is a very simple script that echos quotes from the Infinity-IRC Quote database. */
/* Upload to a web directory and visit the URL. If i uploaded to my site http://iYorkie.co.uk as qdb.php, */
/* I would visit http://iYorkie.co.uk/qdb.php?id=1 to view Quote with ID 1. */
/* This can also be used in PHP IRC Bots, as a way of viewing quotes by IRC */

$id = $_GET['id'];
$url = file_get_contents('http://infinityirc.com/quotes.php?id='.$id);
$url = str_replace('&lt;', '<', $url);
$url = str_replace('&gt;', '>', $url);
$data = explode("</br>", $url);
foreach ($data as $url) {
echo 'Quote '.$id.': '.$url.'</br>';
}

?>